package Player;


public class Environment {
    public Environment(String placeName, Faction controllerFaction, String dayOrNight) throws Exception{
        this.placeName = placeName;
        if(!dayOrNight.equalsIgnoreCase("day") && !dayOrNight.equalsIgnoreCase("night"))
            throw new Exception("illegal argument for day or night");
        this.controllerFaction = controllerFaction;
        this.dayOrNight = dayOrNight;
    }

    public String getPlaceName(){
        return placeName;
    }

    public Faction getFactionThatControlsPlace(){
        return controllerFaction;
    }

    public String getPartOfTheDay(){
        return dayOrNight;
    }

    protected void setFactionThatControlsPlace(Faction controllerFaction){
        this.controllerFaction = controllerFaction;
    }

    private String placeName, dayOrNight;
    private Faction controllerFaction;
}
